/*
 ============================================================================
 Name		: CDirLinkList.h
 Author	  : 
 Version	 : 1.0
 Copyright   : Your copyright notice
 Description : CCDirLinkList declaration
 ============================================================================
 */

#ifndef CDIRLINKLIST_H
#define CDIRLINKLIST_H

// INCLUDES
#include <e32std.h>
#include <e32base.h>
#include <f32file.h>

class CDir;

class CDirNode
{
public:
	CDirNode();
	~CDirNode();
	
public:
	void AppendEntry(TEntry& aEntry);
	RPointerArray<TEntry>& GetEntryArray();
	
private:
	RPointerArray<TEntry>	iEntryArray;	
	
public:		
	CDirNode*  	 			iPrivious;
	CDirNode*   			iNext;
	TParse*					iParse;
};
 
class CDirLinkList : public CBase 
{
public:	 
	~CDirLinkList();	 
	static CDirLinkList* NewL();	 
	static CDirLinkList* NewLC();

private:
	CDirLinkList();
	void ConstructL();	
	
public:
	void AppendNode(CDirNode& aNode);
	void DeleteNode();
	void MoveNext();
	void MovePrivious();
	CDirNode* Current();
	CDirNode* Head();
	CDirNode* Last();
	
private:	 
	CDirNode*  			 iHead;
	CDirNode*  			 iLast;
	CDirNode*  			 iCurrent;
	TInt                 iNodeCount;
	
};

#endif // CDIRLINKLIST_H
